// import path from 'path'
import { ImportsNotUsedAsValues } from 'typescript'
import { createRouter, createWebHistory } from 'vue-router'

const router = createRouter({
  history: createWebHistory(import.meta.env.BASE_URL),
  routes: [
    {path:"/",
      name:"home",
      redirect:"/home",
      component:()=>import("@/layout/index.vue"),
      children:[
        {path:"/home",
          component:()=>import("@/views/home/index.vue")
        }
      ]
    },
    {
      path:"/login",
      name:"login",
      redirect:"/login/list",
      component:()=>import("@/layout/index.vue"),
      children:[
        {path:"/login/list",
          component:()=>import("@/views/login/index.vue")}
      ]
    },
    {path:"/account",
      name:"account",
      redirect:"/account/list",
      component:()=>import("@/layout/index.vue"),
      children:[
        {path:"/account/list",
          component:()=>import("@/views/account/admin.vue")
        },
        {path:"/account/kind",
          component:()=>import("@/views/account/index.vue")
        },
      ]
    },
      {path:"/pro",
      name:"pro",
      redirect:"/pro/list",
      component:()=>import("@/layout/index.vue"),
      children:[
        {path:"/pro/list",
          component:()=>import("@/views/pro/index.vue")
        },
        {path:"/pro/kind",
          component:()=>import("@/views/pro/filter.vue")
        },

      ]
    },
      {path:"/banner",
      name:"banner",
      redirect:"/banner/kind",
      component:()=>import("@/layout/index.vue"),
      children:[
        {path:"/banner/kind",
          component:()=>import("@/views/banner/index.vue"),
          children:[
            {path:"/banner/kind/home",
              component:()=>import("@/views/banner/components/BannerKind.vue")
            },
             {path:"/banner/kind/home",
              component:()=>import("@/views/banner/components/BannerList.vue")
            },
          ]
        }
      ]
    },
  ],

})

export default router
